<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title>TODOlist</title>
		<script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script>
	</head>
	<body>
		<div id="todo-list-demo">
			<form v-on:submit.prevent="addNewTODO">
				<label id="new-one">Add a TODO</label>
				<input v-model="newTODOText"
					id="new-TODO"
					placeholder="E.G. Feed the cat."/>
				<button>Add</button>
			</form>
			<ul>
				<li is="todo-item"
					v-for="(item, index) in todos"
					v-bind:key="item.id"
					v-bind:title="item.text"
					v-on:remove="todos.splice(index, 1)">
				</li>
			</ul>
		</div>
		<script src="../js/todolist.js"></script>
	</body>
</html>
